#create a dataset with just the cross-sectional data 
data_cross_w1 <- data_w1 %>% filter(recontact == 2)
data_cross_w1$wave <- 1
data_cross_w2 <- data_w2 %>% filter(recontact == 2)
data_cross_w2$wave <- 2

#convert variables to numeric
convertcols <- names(data_cross_w1) 
convertcols <- convertcols[-105] #don't include starttime
data_cross_w1[convertcols] <- sapply(data_cross_w1[convertcols],as.numeric)

convertcols <- names(data_cross_w2) 
convertcols <- convertcols[-124] #don't include starttime
data_cross_w2[convertcols] <- sapply(data_cross_w2[convertcols],as.numeric)


#create a datasets with just the panel data
data_w1 <- data_w1 %>% filter(recontact == 1)
data_w1$wave <- 1
data_w2 <- data_w2 %>% filter(recontact == 1)
data_w2$wave <- 2
data_w0$wave <- 0


#convert variables to numeric
convertcols <- names(data_w0) 
convertcols <- convertcols[-123]
data_w0[convertcols] <- sapply(data_w0[convertcols],as.numeric)

convertcols <- names(data_w1) 
convertcols <- convertcols[-105]
data_w1[convertcols] <- sapply(data_w1[convertcols],as.numeric)

convertcols <- names(data_w2) 
convertcols <- convertcols[-124]
data_w2[convertcols] <- sapply(data_w2[convertcols],as.numeric)


####### Clean Wave 0 #########

#combine versions and A and B for baseline questions
data_w0 <- data_w0 %>% mutate(
  personal_dobbs = coalesce(Q1A, Q1B),
  court_dobbs = coalesce(Q2A, Q2B),
  personal_rifle = coalesce(Q5A, Q5B),
  court_rifle = coalesce(Q6A, Q6B))

#change baseline variable names to match our variable names
names(data_w0)[names(data_w0) == 'Q3'] <- 'personal_roe'
names(data_w0)[names(data_w0) == 'Q4'] <- 'court_roe'
names(data_w0)[names(data_w0) == 'Q34'] <- 'justice_tenure'
names(data_w0)[names(data_w0) == 'Q35'] <- 'last_say'
names(data_w0)[names(data_w0) == 'Q36'] <- 'justice_selection'
names(data_w0)[names(data_w0) == 'Q37'] <- 'current_chief'
names(data_w0)[names(data_w0) == 'Q38'] <- 'most_recent'
names(data_w0)[names(data_w0) == 'Q39'] <- 'republican_appointment'
names(data_w0)[names(data_w0) == 'Q41'] <- 'approve_court'
names(data_w0)[names(data_w0) == 'Q42'] <- 'courtlegit_1'
names(data_w0)[names(data_w0) == 'Q43'] <- 'courtlegit_2'
names(data_w0)[names(data_w0) == 'Q44'] <- 'courtlegit_3'
names(data_w0)[names(data_w0) == 'Q45'] <- 'courtlegit_4'
names(data_w0)[names(data_w0) == 'Q46'] <- 'courtlegit_5'
names(data_w0)[names(data_w0) == 'Q47'] <- 'personal_ideology'
names(data_w0)[names(data_w0) == 'Q48'] <- 'courtideology'
names(data_w0)[names(data_w0) == 'Q49'] <- 'courtsize'
names(data_w0)[names(data_w0) == 'Q50'] <- 'courtterms'
data_w0$weight_ps <- data_w0$weight

### reverse code the baseline responses to rifle and dobbs
data_w0$personal_dobbs <- 3-data_w0$personal_dobbs
data_w0$personal_rifle <- 3-data_w0$personal_rifle

#flip msnbc and fox coding to match other waves
data_w0$cablenews[data_w0$cablenews == 2] <- 2.5 
data_w0$cablenews[data_w0$cablenews == 3] <- 2
data_w0$cablenews[data_w0$cablenews == 2.5] <- 3

#rename cablenews to match other waves
data_w0$cable <- data_w0$cablenews

#drop variables from April baseline that are not part of the study 
data_w0 = data_w0[,!grepl("^Q",names(data_w0))]

#add cleaned wave 0 to cross-sectional data 
data_cross_w0 <- data_w0 
data_cross_w0$wave <- 0


#combine back into one panel dataset 
data_w0$pid_mod <- data_w0$pid7
data_panel <- bind_rows(data_w0, data_w1, data_w2)
data_cross <- bind_rows(data_cross_w0, data_cross_w1, data_cross_w2)



#create pid moderator 
mod <- 'pid_mod'
for (id in unique(data_panel$universal_ID)) { #for each unique prolific id
  dp_id <- data_panel[data_panel$universal_ID == id, ] # subset data for participant_i #store the unique id
  data_panel[data_panel$universal_ID == id, mod] <- dp_id[dp_id$wave == 0, mod] #take the demos from wave 1 of that ID and add to the other waves
}

#create date variable
data_panel <- data_panel %>%
  separate(starttime, c("date", "time"), sep=" ")

data_cross <- data_cross %>%
  separate(starttime, c("date", "time"), sep=" ")

####variable recodes (pre-registered) #######
## We will recode some variables in an effort to reduce extraneous options 

#sexuality
#1 Heterosexual/straight, 2 Lesbian/gay woman, 3 Gay man, 4 Bisexual, 5 Other, 6 Prefer not to say 
#--> 1 Straight, 2 Lesbian/Gay/Bisexual, 3 Other/Prefer not to say
data_panel$sexuality3_recoded[data_panel$sexuality == 1] <- 1
data_panel$sexuality3_recoded[data_panel$sexuality == 2] <- 2
data_panel$sexuality3_recoded[data_panel$sexuality == 3] <- 2
data_panel$sexuality3_recoded[data_panel$sexuality == 4] <- 2
data_panel$sexuality3_recoded[data_panel$sexuality == 5] <- 3
data_panel$sexuality3_recoded[data_panel$sexuality == 6] <- 3

#marstat
#1 Married, 2 Separated, 3 Divorced, 4 Widowed, 5 Never Married, 6 Domestic/Civil partnership 
#--> 1 Married, 2 Not Married
data_panel$marstat2_recoded[data_panel$marstat == 1] <- 1
data_panel$marstat2_recoded[data_panel$marstat == 2] <- 2
data_panel$marstat2_recoded[data_panel$marstat == 3] <- 2
data_panel$marstat2_recoded[data_panel$marstat == 4] <- 2
data_panel$marstat2_recoded[data_panel$marstat == 5] <- 2
data_panel$marstat2_recoded[data_panel$marstat == 6] <- 2

#state 
#We will recode the statelaw variable at each wave for whether legislation has been passed 
#or enacted to restrict access to abortion. The format of the recode is produced below
#data_panel$statelaw_recoded[data_panel$state == c()] <- 0 #no restriction
#data_panel$statelaw_recoded[data_panel$state == c()] <- 1 #restriction

#socialclass
#1 rich, 2 upper-middle class, 3 middle class, 4 working class, 5 poor 
#--> 1 upper, 2 middle, 3 working/lower
data_panel$socialclass3_recoded[data_panel$socialclass == 1] <- 3
data_panel$socialclass3_recoded[data_panel$socialclass == 2] <- 3
data_panel$socialclass3_recoded[data_panel$socialclass == 3] <- 2
data_panel$socialclass3_recoded[data_panel$socialclass == 4] <- 1
data_panel$socialclass3_recoded[data_panel$socialclass == 5] <- 1

#pew_religimp
#1 very important, 2 somewhat important, 3 not too important, 4 not at all important
#--> 1 important, 2 not important 
data_panel$religimp2_recoded[data_panel$pew_religimp == 1] <- 1
data_panel$religimp2_recoded[data_panel$pew_religimp == 2] <- 1
data_panel$religimp2_recoded[data_panel$pew_religimp == 3] <- 0
data_panel$religimp2_recoded[data_panel$pew_religimp == 4] <- 0

#pew_churatd
#1 more than once per week, 2 once a week, 3 once or twice a month, 4 a few times a year, 
#5 seldom, 6 never, 7 don't know 
#--> 3 weekly, 2 monthly, 1 rarely or never
data_panel$churatd3_recoded[data_panel$pew_churatd == 1] <- 3
data_panel$churatd3_recoded[data_panel$pew_churatd == 2] <- 3
data_panel$churatd3_recoded[data_panel$pew_churatd == 3] <- 2
data_panel$churatd3_recoded[data_panel$pew_churatd == 4] <- 1
data_panel$churatd3_recoded[data_panel$pew_churatd == 5] <- 1
data_panel$churatd3_recoded[data_panel$pew_churatd == 6] <- 1
data_panel$churatd3_recoded[data_panel$pew_churatd == 7] <- 1

#religpew
#1 protestant, 2 roman catholic, 3 mormon, 4 eastern orthodox, 5 jewish, 6 muslim, 
#7 buddhist, 8 hindu, 9 athiest, 10 agnostic, 11 nothing in particular, 12 something else 
#--> 1 protestant, 2 catholic/eastern orthodox, 3 mormon, 4 jewish, 6 muslim, 7 buddhist, 
#8 hindu, 9 non religious, 12 other
data_panel$relig_recoded[data_panel$religpew == 1] <- 1
data_panel$relig_recoded[data_panel$religpew == 2] <- 2
data_panel$relig_recoded[data_panel$religpew == 3] <- 3
data_panel$relig_recoded[data_panel$religpew == 4] <- 2
data_panel$relig_recoded[data_panel$religpew == 5] <- 4
data_panel$relig_recoded[data_panel$religpew == 6] <- 5
data_panel$relig_recoded[data_panel$religpew == 7] <- 6
data_panel$relig_recoded[data_panel$religpew == 8] <- 7
data_panel$relig_recoded[data_panel$religpew == 9] <- 8
data_panel$relig_recoded[data_panel$religpew == 10] <- 8
data_panel$relig_recoded[data_panel$religpew == 11] <- 8
data_panel$relig_recoded[data_panel$religpew == 12] <- 9

#Both the relig and bornagain variables will be recoded into one indicator of 
#religion's views on abortion 
#--> 1 born again, evangelical christian, roman catholic, or eastern orthodox, 0 other
data_panel$religion_prolife_recoded <- 0
data_panel$religion_prolife_recoded[(data_panel$pew_bornagain == 1 | data_panel$religpew == 2 | data_panel$religpew ==4)] <- 1

#affective polarization
data_panel$affectivepolarization <- NA
data_panel$inparty <- NA
data_panel$outparty <- NA

data_panel$inparty[which(data_panel$pid3==1)] <- data_panel$dem_feelings[which(data_panel$pid3==1)] #dem = 1
data_panel$inparty[which(data_panel$pid3==2)] <- data_panel$rep_feelings[which(data_panel$pid3==2)] #repub = 2

data_panel$outparty[which(data_panel$pid3==2)] <- data_panel$dem_feelings[which(data_panel$pid3==2)] #repub = 2
data_panel$outparty[which(data_panel$pid3==1)] <- data_panel$rep_feelings[which(data_panel$pid3==1)] #dem = 1

data_panel$affectivepolarization <- data_panel$inparty -data_panel$outparty

#personal_ideology 
#0: extremely liberaly to 100: extremely conservative
#--> 1 liberal leaning, 2 neutral, 3 conservative leaning 
data_panel$personal_ideology <- as.numeric(data_panel$personal_ideology)
data_panel$personal_ideology_recoded[data_panel$personal_ideology < 50] <- 1
data_panel$personal_ideology_recoded[data_panel$personal_ideology == 50] <- 2
data_panel$personal_ideology_recoded[data_panel$personal_ideology > 50] <- 3

#pride
#1 very proud, 2 somewhat proud, 3 neutral, 4 not very proud, 5 not proud, 6 not from US 
#--> 3 proud, 2 neutral, 1 not proud
data_panel$pride <- as.numeric(data_panel$pride)
data_panel$pride_recoded[data_panel$pride == 1] <- 3
data_panel$pride_recoded[data_panel$pride == 2] <- 3
data_panel$pride_recoded[data_panel$pride == 3] <- 2
data_panel$pride_recoded[data_panel$pride == 4] <- 1
data_panel$pride_recoded[data_panel$pride == 5] <- 1
data_panel$pride_recoded[data_panel$pride == 6] <- 0

#create a usnative binary variable 
data_panel$usnative_recoded[data_panel$pride < 6] <- 1
data_panel$usnative_recoded[data_panel$pride == 6] <- 0

#political_interest
# 1 most of time, 2 some of time, 3 only now and then, 4 hardly at all, 5 don't know 
#--> 2 some interest, 1 no interest
data_panel$political_interest <- as.numeric(data_panel$political_interest)
data_panel$political_interest_recoded[data_panel$political_interest == 1] <- 2
data_panel$political_interest_recoded[data_panel$political_interest == 2] <- 2
data_panel$political_interest_recoded[data_panel$political_interest == 3] <- 2
data_panel$political_interest_recoded[data_panel$political_interest == 4] <- 1
data_panel$political_interest_recoded[data_panel$political_interest == 5] <- 1

#importance
#1 not at all important, 2 not too important, 3 somewhat important, 4 very important, 5 extremely important 
#--> 0 not important, 1 important
data_panel$importance_recoded[data_panel$importance == 1] <- 0
data_panel$importance_recoded[data_panel$importance == 2] <- 0
data_panel$importance_recoded[data_panel$importance == 3] <- 1
data_panel$importance_recoded[data_panel$importance == 4] <- 1
data_panel$importance_recoded[data_panel$importance == 5] <- 1

#cable
data_panel$cable_cnn[data_panel$cable == 1] <- 1
data_panel$cable_cnn[data_panel$cable != 1] <- 0
data_panel$cable_msnbc[data_panel$cable == 2] <- 1
data_panel$cable_msnbc[data_panel$cable != 2] <- 0
data_panel$cable_fox[data_panel$cable == 3] <- 1
data_panel$cable_fox[data_panel$cable != 3] <- 0
data_panel$cable_other[data_panel$cable == 4] <- 1
data_panel$cable_other[data_panel$cable != 4] <- 0
data_panel$cable_none[data_panel$cable == 5] <- 1
data_panel$cable_none[data_panel$cable != 5] <- 0
#If any of the "other" responses fall into one of these categories, it will be added by hand to the proper category. 
#otherwise, it will remain in the other category. 

#approve_court (coded such that higher values = more approval)
data_panel$approve_court <- (data_panel$approve_court-5)/-4

#1 strongly approve, 2 somewhat approve, 3 neither approve nor disapprove, 
#4 somewhat disapprove, 5 strongly disapprove
#--> 3 approve, 2 neutral, 1 disapprove
data_panel$approve_court_recoded[data_panel$approve_court == 1] <- 3
data_panel$approve_court_recoded[data_panel$approve_court == 2] <- 3
data_panel$approve_court_recoded[data_panel$approve_court == 3] <- 2
data_panel$approve_court_recoded[data_panel$approve_court == 4] <- 1
data_panel$approve_court_recoded[data_panel$approve_court == 5] <- 1


### Court Legitimacy composite #####

# Our original plan is to average the items, but we will also explore whether the factors load and we reserve 
#the possibility that we will examine items separately or use as a factor score. 

#courtlegit_composite coded such that higher numbers indicate #more perceived legitimacy

# courtlegit_1 : courtlegit_5 + court_represent 
#1 strongly agree, 2 agree, 3 neither agree nor disagree, 
#4 disagree, 5 strongly disagree
#courtlegit_5 and court_represent are coded backwards

data_panel$courtlegit_1 <- (data_panel$courtlegit_1-1)/4
data_panel$courtlegit_2 <- (data_panel$courtlegit_2-1)/4
data_panel$courtlegit_3 <- (data_panel$courtlegit_3-1)/4
data_panel$courtlegit_4 <- (data_panel$courtlegit_4-1)/4
data_panel$courtlegit_5 <- (6-data_panel$courtlegit_5) #reverse code 
data_panel$courtlegit_5 <- (data_panel$courtlegit_5-1)/4
data_panel$courtlegit_composite <- (data_panel$courtlegit_1 + data_panel$courtlegit_2 + data_panel$courtlegit_3 + 
                                      data_panel$courtlegit_4 + data_panel$courtlegit_5)/5
#data_panel$courtlegit_composite <- round(data_panel$courtlegit_composite, digits = 0) 
#we forgot to pre-register this step ^, but it is necessary for the next pre-registered step

#--> 1 not legit, 2 somewhat legit, 3 legit
# data_panel$courtlegit_recoded[data_panel$courtlegit_composite == 1] <- 1
# data_panel$courtlegit_recoded[data_panel$courtlegit_composite == 2] <- 1
# data_panel$courtlegit_recoded[data_panel$courtlegit_composite == 3] <- 2
# data_panel$courtlegit_recoded[data_panel$courtlegit_composite == 4] <- 3
# data_panel$courtlegit_recoded[data_panel$courtlegit_composite == 5] <- 3

#court_represent (coded such that higher values = more support)
##1 strongly agree, 2 agree, 3 neither agree nor disagree, 4 disagree, 5 strongly disagree
#--> 3 agree, 2 neither agree nor disagree, 1 disagree
data_panel$court_represent_recoded[data_panel$court_represent == 1] <- 3
data_panel$court_represent_recoded[data_panel$court_represent == 2] <- 3
data_panel$court_represent_recoded[data_panel$court_represent == 3] <- 2
data_panel$court_represent_recoded[data_panel$court_represent == 4] <- 1
data_panel$court_represent_recoded[data_panel$court_represent == 5] <- 1

#courtideology
#0: extremely liberaly to 100: extremely conservative
#--> 1 liberal leaning, 2 neutral, 3 conservative leaning 
data_panel$courtideology_recoded[data_panel$courtideology < 50] <- 1
data_panel$courtideology_recoded[data_panel$courtideology == 50] <- 2
data_panel$courtideology_recoded[data_panel$courtideology > 50] <- 3

#courtsize (coded such that higher values = more support for proposal)
data_panel$courtsize <- (data_panel$courtsize-5)/-4

#1 strongly agree, 2 agree, 3 neither agree nor disagree, 4 disagree, 5 strongly disagree
#--> 3 agree, 2 neither agree nor disagree, 1 disagree
data_panel$courtsize_recoded[data_panel$courtsize == 1] <- 3
data_panel$courtsize_recoded[data_panel$courtsize == 2] <- 3
data_panel$courtsize_recoded[data_panel$courtsize == 3] <- 2
data_panel$courtsize_recoded[data_panel$courtsize == 4] <- 1
data_panel$courtsize_recoded[data_panel$courtsize == 5] <- 1

#courtterms (coded such that higher values = more support for proposal)
data_panel$courtterms <- (data_panel$courtterms-5)/-4

#1 strongly agree, 2 agree, 3 neither agree nor disagree, 4 disagree, 5 strongly disagree
#--> 3 agree, 2 neither agree nor disagree, 1 disagree
data_panel$courtterms_recoded[data_panel$courtterms == 1] <- 3
data_panel$courtterms_recoded[data_panel$courtterms == 2] <- 3
data_panel$courtterms_recoded[data_panel$courtterms == 3] <- 2
data_panel$courtterms_recoded[data_panel$courtterms == 4] <- 1
data_panel$courtterms_recoded[data_panel$courtterms == 5] <- 1

# Supreme Court knowledge
#current_chief, most_recent, justice_selection, justice_tenure, last_say, republican_appointment
#correct answers = 1, all others = 0
#answered then averaged into composite score 
data_panel$courtknow1[data_panel$current_chief == 4] <- 1
data_panel$courtknow1[data_panel$current_chief != 4] <- 0
data_panel$courtknow2[data_panel$most_recent == 5] <- 1
data_panel$courtknow2[data_panel$most_recent != 5] <- 0
data_panel$courtknow3[data_panel$justice_selection == 2] <- 1
data_panel$courtknow3[data_panel$justice_selection != 2] <- 0
data_panel$courtknow4[data_panel$justice_tenure == 2] <- 1
data_panel$courtknow4[data_panel$justice_tenure != 2] <- 0
data_panel$courtknow5[data_panel$last_say == 2] <- 1
data_panel$courtknow5[data_panel$last_say != 2] <- 0
data_panel$courtknow6[data_panel$republican_appointment == 6] <- 1
data_panel$courtknow6[data_panel$republican_appointment != 6] <- 0

data_panel$courtknow_composite <- (data_panel$courtknow1 + data_panel$courtknow2 + data_panel$courtknow3 + 
                                     data_panel$courtknow4 + data_panel$courtknow5 + data_panel$courtknow6)/6
data_panel$courtknow_composite <- round(data_panel$courtknow_composite, digits = 0) #### IS THIS WHAT WE WANT TO DO? NOT PRE-REGISTERED

#rename info_source variables to be more descriptive
names(data_panel)[names(data_panel) == 'info_source_1'] <- 'info_source_sm'
names(data_panel)[names(data_panel) == 'info_source_2'] <- 'info_source_cable'
names(data_panel)[names(data_panel) == 'info_source_3'] <- 'info_source_local'
names(data_panel)[names(data_panel) == 'info_source_4'] <- 'info_source_friend'
names(data_panel)[names(data_panel) == 'info_source_5'] <- 'info_source_online'
names(data_panel)[names(data_panel) == 'info_source_6'] <- 'info_source_newspaper'
names(data_panel)[names(data_panel) == 'info_source_7'] <- 'info_source_email'
names(data_panel)[names(data_panel) == 'info_source_8'] <- 'info_source_church'
names(data_panel)[names(data_panel) == 'info_source_9'] <- 'info_source_other_binary'

#recode binaries to 0 and 1 
data_panel$personal_roe[data_panel$personal_roe == 2] <- 0
data_panel$court_roe[data_panel$court_roe == 2] <- 0
data_panel$personal_dobbs[data_panel$personal_dobbs == 2] <- 0
data_panel$court_dobbs[data_panel$court_dobbs == 2] <- 0
data_panel$personal_rifle[data_panel$personal_rifle == 2] <- 0
data_panel$court_rifle[data_panel$court_rifle == 2] <- 0
data_panel$votereg2[data_panel$votereg2 == 2] <- 0
data_panel$turnout20post[data_panel$turnout20post == 2] <- 0
data_panel$gender[data_panel$gender == 2] <- 0
data_panel$child18[data_panel$child18 == 2] <- 0
data_panel$pew_bornagain[data_panel$pew_bornagain == 2] <- 0

data_panel$behavior[data_panel$behavior == 2] <- 0
data_panel$personal_affirmative[data_panel$personal_affirmative == 2] <- 0
data_panel$court_affirmative[data_panel$court_affirmative == 2] <- 0
data_panel$info_source_sm[data_panel$info_source_sm == 2] <- 0
data_panel$info_source_cable[data_panel$info_source_cable == 2] <- 0
data_panel$info_source_local[data_panel$info_source_local == 2] <- 0
data_panel$info_source_friend[data_panel$info_source_friend == 2] <- 0
data_panel$info_source_online[data_panel$info_source_online == 2] <- 0
data_panel$info_source_newspaper[data_panel$info_source_newspaper == 2] <- 0
data_panel$info_source_email[data_panel$info_source_email == 2] <- 0
data_panel$info_source_church[data_panel$info_source_church == 2] <- 0
data_panel$info_source_other_binary[data_panel$info_source_other_binary == 2] <- 0

table(data_panel$opinion)

#re-scale opinion and norms 
data_panel$opinion <- 1-((data_panel$opinion-1)/4)
data_panel$moral_opinion <- 1-((data_panel$moral_opinion-1)/4)
data_panel$norm <- 1-((data_panel$norm-1)/4)
data_panel$moral_norm <- 1-((data_panel$moral_norm-1)/4)


#awareness check (if aware of leak, aware_panel == 1)
data_panel <- data_panel %>% 
  mutate(aware = ifelse(awareness == 4, 1, 0))

#binary treatment indicator (treated_panel = 1 if treated)
data_panel <- data_panel %>% 
  mutate(treated = ifelse(awareness_treatment == 3, 1, 0))

#create cable news binary indicator (0 = doesn't watch cable news)
data_panel$news_binary[data_panel$cable < 5] <- 1
data_panel$news_binary[data_panel$cable == 5] <- 0



####### Clean Cross Dataset #########

#sexuality
#1 Heterosexual/straight, 2 Lesbian/gay woman, 3 Gay man, 4 Bisexual, 5 Other, 6 Prefer not to say 
#--> 1 Straight, 2 Lesbian/Gay/Bisexual, 3 Other/Prefer not to say
data_cross$sexuality3_recoded[data_cross$sexuality == 1] <- 1
data_cross$sexuality3_recoded[data_cross$sexuality == 2] <- 2
data_cross$sexuality3_recoded[data_cross$sexuality == 3] <- 2
data_cross$sexuality3_recoded[data_cross$sexuality == 4] <- 2
data_cross$sexuality3_recoded[data_cross$sexuality == 5] <- 3
data_cross$sexuality3_recoded[data_cross$sexuality == 6] <- 3

#marstat
#1 Married, 2 Separated, 3 Divorced, 4 Widowed, 5 Never Married, 6 Domestic/Civil partnership 
#--> 1 Married, 2 Not Married
data_cross$marstat2_recoded[data_cross$marstat == 1] <- 1
data_cross$marstat2_recoded[data_cross$marstat == 2] <- 2
data_cross$marstat2_recoded[data_cross$marstat == 3] <- 2
data_cross$marstat2_recoded[data_cross$marstat == 4] <- 2
data_cross$marstat2_recoded[data_cross$marstat == 5] <- 2
data_cross$marstat2_recoded[data_cross$marstat == 6] <- 2

#state 
#We will recode the statelaw variable at each wave for whether legislation has been passed 
#or enacted to restrict access to abortion. The format of the recode is produced below
#data_cross$statelaw_recoded[data_cross$state == c()] <- 0 #no restriction
#data_cross$statelaw_recoded[data_cross$state == c()] <- 1 #restriction

#socialclass
#1 rich, 2 upper-middle class, 3 middle class, 4 working class, 5 poor 
#--> 1 upper, 2 middle, 3 working/lower
data_cross$socialclass3_recoded[data_cross$socialclass == 1] <- 3
data_cross$socialclass3_recoded[data_cross$socialclass == 2] <- 3
data_cross$socialclass3_recoded[data_cross$socialclass == 3] <- 2
data_cross$socialclass3_recoded[data_cross$socialclass == 4] <- 1
data_cross$socialclass3_recoded[data_cross$socialclass == 5] <- 1

#pew_religimp
#1 very important, 2 somewhat important, 3 not too important, 4 not at all important
#--> 1 important, 2 not important 
data_cross$religimp2_recoded[data_cross$pew_religimp == 1] <- 1
data_cross$religimp2_recoded[data_cross$pew_religimp == 2] <- 1
data_cross$religimp2_recoded[data_cross$pew_religimp == 3] <- 0
data_cross$religimp2_recoded[data_cross$pew_religimp == 4] <- 0

#pew_churatd
#1 more than once per week, 2 once a week, 3 once or twice a month, 4 a few times a year, 
#5 seldom, 6 never, 7 don't know 
#--> 3 weekly, 2 monthly, 1 rarely or never
data_cross$churatd3_recoded[data_cross$pew_churatd == 1] <- 3
data_cross$churatd3_recoded[data_cross$pew_churatd == 2] <- 3
data_cross$churatd3_recoded[data_cross$pew_churatd == 3] <- 2
data_cross$churatd3_recoded[data_cross$pew_churatd == 4] <- 1
data_cross$churatd3_recoded[data_cross$pew_churatd == 5] <- 1
data_cross$churatd3_recoded[data_cross$pew_churatd == 6] <- 1
data_cross$churatd3_recoded[data_cross$pew_churatd == 7] <- 1

#religpew
#1 protestant, 2 roman catholic, 3 mormon, 4 eastern orthodox, 5 jewish, 6 muslim, 
#7 buddhist, 8 hindu, 9 athiest, 10 agnostic, 11 nothing in particular, 12 something else 
#--> 1 protestant, 2 catholic/eastern orthodox, 3 mormon, 4 jewish, 6 muslim, 7 buddhist, 
#8 hindu, 9 non religious, 12 other
data_cross$relig_recoded[data_cross$religpew == 1] <- 1
data_cross$relig_recoded[data_cross$religpew == 2] <- 2
data_cross$relig_recoded[data_cross$religpew == 3] <- 3
data_cross$relig_recoded[data_cross$religpew == 4] <- 2
data_cross$relig_recoded[data_cross$religpew == 5] <- 4
data_cross$relig_recoded[data_cross$religpew == 6] <- 5
data_cross$relig_recoded[data_cross$religpew == 7] <- 6
data_cross$relig_recoded[data_cross$religpew == 8] <- 7
data_cross$relig_recoded[data_cross$religpew == 9] <- 8
data_cross$relig_recoded[data_cross$religpew == 10] <- 8
data_cross$relig_recoded[data_cross$religpew == 11] <- 8
data_cross$relig_recoded[data_cross$religpew == 12] <- 9

#Both the relig and bornagain variables will be recoded into one indicator of 
#religion's views on abortion 
#--> 1 born again, evangelical christian, roman catholic, or eastern orthodox, 0 other
data_cross$religion_prolife_recoded <- 0
data_cross$religion_prolife_recoded[(data_cross$pew_bornagain == 1 | data_cross$religpew == 2 | data_cross$religpew ==4)] <- 1

#affective polarization
data_cross$affectivepolarization <- NA
data_cross$inparty <- NA
data_cross$outparty <- NA

data_cross$inparty[which(data_cross$pid3==1)] <- data_cross$dem_feelings[which(data_cross$pid3==1)] #dem = 1
data_cross$inparty[which(data_cross$pid3==2)] <- data_cross$rep_feelings[which(data_cross$pid3==2)] #repub = 2

data_cross$outparty[which(data_cross$pid3==2)] <- data_cross$dem_feelings[which(data_cross$pid3==2)] #repub = 2
data_cross$outparty[which(data_cross$pid3==1)] <- data_cross$rep_feelings[which(data_cross$pid3==1)] #dem = 1

data_cross$affectivepolarization <- data_cross$inparty -data_cross$outparty

#personal_ideology 
#0: extremely liberaly to 100: extremely conservative
#--> 1 liberal leaning, 2 neutral, 3 conservative leaning 
data_cross$personal_ideology <- as.numeric(data_cross$personal_ideology)
data_cross$personal_ideology_recoded[data_cross$personal_ideology < 50] <- 1 #liberal
data_cross$personal_ideology_recoded[data_cross$personal_ideology == 50] <- 2 # neutral
data_cross$personal_ideology_recoded[data_cross$personal_ideology > 50] <- 3 # conservative

#pride
#1 very proud, 2 somewhat proud, 3 neutral, 4 not very proud, 5 not proud, 6 not from US 
#--> 3 proud, 2 neutral, 1 not proud
data_cross$pride <- as.numeric(data_cross$pride)
data_cross$pride_recoded[data_cross$pride == 1] <- 3
data_cross$pride_recoded[data_cross$pride == 2] <- 3
data_cross$pride_recoded[data_cross$pride == 3] <- 2
data_cross$pride_recoded[data_cross$pride == 4] <- 1
data_cross$pride_recoded[data_cross$pride == 5] <- 1
data_cross$pride_recoded[data_cross$pride == 6] <- 0

#create a usnative binary variable 
data_cross$usnative_recoded[data_cross$pride < 6] <- 1
data_cross$usnative_recoded[data_cross$pride == 6] <- 0

#political_interest
# 1 most of time, 2 some of time, 3 only now and then, 4 hardly at all, 5 don't know 
#--> 2 some interest, 1 no interest
data_cross$political_interest <- as.numeric(data_cross$political_interest)
data_cross$political_interest_recoded[data_cross$political_interest == 1] <- 2
data_cross$political_interest_recoded[data_cross$political_interest == 2] <- 2
data_cross$political_interest_recoded[data_cross$political_interest == 3] <- 2
data_cross$political_interest_recoded[data_cross$political_interest == 4] <- 1
data_cross$political_interest_recoded[data_cross$political_interest == 5] <- 1

#importance
#1 not at all important, 2 not too important, 3 somewhat important, 4 very important, 5 extremely important 
#--> 0 not important, 1 important
data_cross$importance_recoded[data_cross$importance == 1] <- 0
data_cross$importance_recoded[data_cross$importance == 2] <- 0
data_cross$importance_recoded[data_cross$importance == 3] <- 1
data_cross$importance_recoded[data_cross$importance == 4] <- 1
data_cross$importance_recoded[data_cross$importance == 5] <- 1

#cable
data_cross$cable_cnn[data_cross$cable == 1] <- 1
data_cross$cable_cnn[data_cross$cable != 1] <- 0
data_cross$cable_msnbc[data_cross$cable == 2] <- 1
data_cross$cable_msnbc[data_cross$cable != 2] <- 0
data_cross$cable_fox[data_cross$cable == 3] <- 1
data_cross$cable_fox[data_cross$cable != 3] <- 0
data_cross$cable_other[data_cross$cable == 4] <- 1
data_cross$cable_other[data_cross$cable != 4] <- 0
data_cross$cable_none[data_cross$cable == 5] <- 1
data_cross$cable_none[data_cross$cable != 5] <- 0
#If any of the "other" responses fall into one of these categories, it will be added by hand to the proper category. 
#otherwise, it will remain in the other category. 

#approve_court (coded such that higher values = more approval)
data_cross$approve_court <- (data_cross$approve_court-5)/-4

#1 strongly approve, 2 somewhat approve, 3 neither approve nor disapprove, 
#4 somewhat disapprove, 5 strongly disapprove
#--> 3 approve, 2 neutral, 1 disapprove
data_cross$approve_court_recoded[data_cross$approve_court == 1] <- 3
data_cross$approve_court_recoded[data_cross$approve_court == 2] <- 3
data_cross$approve_court_recoded[data_cross$approve_court == 3] <- 2
data_cross$approve_court_recoded[data_cross$approve_court == 4] <- 1
data_cross$approve_court_recoded[data_cross$approve_court == 5] <- 1


### Court Legitimacy composite #####

# Our original plan is to average the items, but we will also explore whether the factors load and we reserve 
#the possibility that we will examine items separately or use as a factor score. 

#courtlegit_composite coded such that higher numbers indicate #more perceived legitimacy

# courtlegit_1 : courtlegit_5 + court_represent 
#1 strongly agree, 2 agree, 3 neither agree nor disagree, 
#4 disagree, 5 strongly disagree
#courtlegit_5 and court_represent are coded backwards

data_cross$courtlegit_1 <- (data_cross$courtlegit_1-1)/4
data_cross$courtlegit_2 <- (data_cross$courtlegit_2-1)/4
data_cross$courtlegit_3 <- (data_cross$courtlegit_3-1)/4
data_cross$courtlegit_4 <- (data_cross$courtlegit_4-1)/4
data_cross$courtlegit_5 <- (6-data_cross$courtlegit_5) #reverse code 
data_cross$courtlegit_5 <- (data_cross$courtlegit_5-1)/4
data_cross$courtlegit_composite <- (data_cross$courtlegit_1 + data_cross$courtlegit_2 + data_cross$courtlegit_3 + 
                                      data_cross$courtlegit_4 + data_cross$courtlegit_5)/5

#we forgot to pre-register this step ^, but it is necessary for the next pre-registered step

#--> 1 not legit, 2 somewhat legit, 3 legit
# data_cross$courtlegit_composite <- round(data_cross$courtlegit_composite, digits = 0) 
# data_cross$courtlegit_recoded[data_cross$courtlegit_composite == 1] <- 1
# data_cross$courtlegit_recoded[data_cross$courtlegit_composite == 2] <- 1
# data_cross$courtlegit_recoded[data_cross$courtlegit_composite == 3] <- 2
# data_cross$courtlegit_recoded[data_cross$courtlegit_composite == 4] <- 3
# data_cross$courtlegit_recoded[data_cross$courtlegit_composite == 5] <- 3

#court_represent (coded such that higher values = more support)
##1 strongly agree, 2 agree, 3 neither agree nor disagree, 4 disagree, 5 strongly disagree
#--> 3 agree, 2 neither agree nor disagree, 1 disagree
data_cross$court_represent_recoded[data_cross$court_represent == 1] <- 3
data_cross$court_represent_recoded[data_cross$court_represent == 2] <- 3
data_cross$court_represent_recoded[data_cross$court_represent == 3] <- 2
data_cross$court_represent_recoded[data_cross$court_represent == 4] <- 1
data_cross$court_represent_recoded[data_cross$court_represent == 5] <- 1

#courtideology
#0: extremely liberaly to 100: extremely conservative
#--> 1 liberal leaning, 2 neutral, 3 conservative leaning 
data_cross$courtideology_recoded[data_cross$courtideology < 50] <- 1
data_cross$courtideology_recoded[data_cross$courtideology == 50] <- 2
data_cross$courtideology_recoded[data_cross$courtideology > 50] <- 3

#courtsize (coded such that higher values = more support for proposal)
data_cross$courtsize <- (data_cross$courtsize-5)/-4

#1 strongly agree, 2 agree, 3 neither agree nor disagree, 4 disagree, 5 strongly disagree
#--> 3 agree, 2 neither agree nor disagree, 1 disagree
data_cross$courtsize_recoded[data_cross$courtsize == 1] <- 3
data_cross$courtsize_recoded[data_cross$courtsize == 2] <- 3
data_cross$courtsize_recoded[data_cross$courtsize == 3] <- 2
data_cross$courtsize_recoded[data_cross$courtsize == 4] <- 1
data_cross$courtsize_recoded[data_cross$courtsize == 5] <- 1

#courtterms (coded such that higher values = more support for proposal)
data_cross$courtterms <- (data_cross$courtterms-5)/-4

#1 strongly agree, 2 agree, 3 neither agree nor disagree, 4 disagree, 5 strongly disagree
#--> 3 agree, 2 neither agree nor disagree, 1 disagree
data_cross$courtterms_recoded[data_cross$courtterms == 1] <- 3
data_cross$courtterms_recoded[data_cross$courtterms == 2] <- 3
data_cross$courtterms_recoded[data_cross$courtterms == 3] <- 2
data_cross$courtterms_recoded[data_cross$courtterms == 4] <- 1
data_cross$courtterms_recoded[data_cross$courtterms == 5] <- 1

# Supreme Court knowledge
#current_chief, most_recent, justice_selection, justice_tenure, last_say, republican_appointment
#correct answers = 1, all others = 0
#answered then averaged into composite score 
data_cross$courtknow2[data_cross$current_chief == 4] <- 1
data_cross$courtknow2[data_cross$current_chief != 4] <- 0
data_cross$courtknow2[data_cross$most_recent == 5] <- 1
data_cross$courtknow2[data_cross$most_recent != 5] <- 0
data_cross$courtknow3[data_cross$justice_selection == 2] <- 1
data_cross$courtknow3[data_cross$justice_selection != 2] <- 0
data_cross$courtknow4[data_cross$justice_tenure == 2] <- 1
data_cross$courtknow4[data_cross$justice_tenure != 2] <- 0
data_cross$courtknow5[data_cross$last_say == 2] <- 1
data_cross$courtknow5[data_cross$last_say != 2] <- 0
data_cross$courtknow6[data_cross$republican_appointment == 6] <- 1
data_cross$courtknow6[data_cross$republican_appointment != 6] <- 0

data_cross$courtknow_composite <- (data_cross$courtknow2 + data_cross$courtknow2 + data_cross$courtknow3 + 
                                     data_cross$courtknow4 + data_cross$courtknow5 + data_cross$courtknow6)/6
data_cross$courtknow_composite <- round(data_cross$courtknow_composite, digits = 0) #### IS THIS WHAT WE WANT TO DO? NOT PRE-REGISTERED

#rename info_source variables to be more descriptive
names(data_cross)[names(data_cross) == 'info_source_1'] <- 'info_source_sm'
names(data_cross)[names(data_cross) == 'info_source_2'] <- 'info_source_cable'
names(data_cross)[names(data_cross) == 'info_source_3'] <- 'info_source_local'
names(data_cross)[names(data_cross) == 'info_source_4'] <- 'info_source_friend'
names(data_cross)[names(data_cross) == 'info_source_5'] <- 'info_source_online'
names(data_cross)[names(data_cross) == 'info_source_6'] <- 'info_source_newspaper'
names(data_cross)[names(data_cross) == 'info_source_7'] <- 'info_source_email'
names(data_cross)[names(data_cross) == 'info_source_8'] <- 'info_source_church'
names(data_cross)[names(data_cross) == 'info_source_9'] <- 'info_source_other_binary'

#recode binaries to 0 and 1 
data_cross$personal_roe[data_cross$personal_roe == 2] <- 0
data_cross$personal_dobbs[data_cross$personal_dobbs == 2] <- 0
data_cross$personal_rifle[data_cross$personal_rifle == 2] <- 0
data_cross$votereg2[data_cross$votereg2 == 2] <- 0
data_cross$turnout20post[data_cross$turnout20post == 2] <- 0
data_cross$gender[data_cross$gender == 2] <- 0
data_cross$child18[data_cross$child18 == 2] <- 0
data_cross$pew_bornagain[data_cross$pew_bornagain == 2] <- 0

data_cross$behavior[data_cross$behavior == 2] <- 0
data_cross$personal_affirmative[data_cross$personal_affirmative == 2] <- 0
data_cross$court_affirmative[data_cross$court_affirmative == 2] <- 0
data_cross$info_source_sm[data_cross$info_source_sm == 2] <- 0
data_cross$info_source_cable[data_cross$info_source_cable == 2] <- 0
data_cross$info_source_local[data_cross$info_source_local == 2] <- 0
data_cross$info_source_friend[data_cross$info_source_friend == 2] <- 0
data_cross$info_source_online[data_cross$info_source_online == 2] <- 0
data_cross$info_source_newspaper[data_cross$info_source_newspaper == 2] <- 0
data_cross$info_source_email[data_cross$info_source_email == 2] <- 0
data_cross$info_source_church[data_cross$info_source_church == 2] <- 0
data_cross$info_source_other_binary[data_cross$info_source_other_binary == 2] <- 0

# #reverse code abortion opinion and norms 
data_cross$opinion <- 1-((data_cross$opinion-1)/4)
data_cross$moral_opinion <- 1-((data_cross$moral_opinion-1)/4)
data_cross$norm <- 1-((data_cross$norm-1)/4)
data_cross$moral_norm <- 1-((data_cross$moral_norm-1)/4)


#awareness check (if aware of leak, aware_cross == 1)
data_cross <- data_cross %>% 
  mutate(aware = ifelse(awareness == 4, 1, 0))

#binary treatment indicator (treated_cross = 1 if treated)
data_cross <- data_cross %>% 
  mutate(treated = ifelse(awareness_treatment == 3, 1, 0))

#create cable news binary indicator (0 = doesn't watch cable news)
data_cross$news_binary[data_cross$cable < 5] <- 1
data_cross$news_binary[data_cross$cable == 5] <- 0


##################################################
########### code lagged dvs ######################
##################################################

#only in panel dataset

#personal dobbs
ids = unique(data_panel$universal_ID)
data_panel$lagged_personal_dobbs <- NA
for(j in 1: length(unique(data_panel$universal_ID))){
  indiv <- data_panel[data_panel$universal_ID == ids[j],]
  data_panel$lagged_personal_dobbs[data_panel$universal_ID == ids[j] & data_panel$wave == 0] <- NA
  data_panel$lagged_personal_dobbs[data_panel$universal_ID == ids[j] & data_panel$wave == 1] <- data_panel$personal_dobbs[data_panel$universal_ID == ids[j] & data_panel$wave == 0]
  data_panel$lagged_personal_dobbs[data_panel$universal_ID == ids[j] & data_panel$wave == 2] <- data_panel$personal_dobbs[data_panel$universal_ID == ids[j] & data_panel$wave == 1]
  
}

#personal roe
data_panel$lagged_personal_roe <- NA
for(j in 1: length(unique(data_panel$universal_ID))){
  indiv <- data_panel[data_panel$universal_ID == ids[j],]
  data_panel$lagged_personal_roe[data_panel$universal_ID == ids[j] & data_panel$wave == 0] <- NA
  data_panel$lagged_personal_roe[data_panel$universal_ID == ids[j] & data_panel$wave == 1] <- data_panel$personal_roe[data_panel$universal_ID == ids[j] & data_panel$wave == 0]
  data_panel$lagged_personal_roe[data_panel$universal_ID == ids[j] & data_panel$wave == 2] <- data_panel$personal_roe[data_panel$universal_ID == ids[j] & data_panel$wave == 1]
  
}

#personal rifle
data_panel$lagged_personal_rifle <- NA
for(j in 1: length(unique(data_panel$universal_ID))){
  indiv <- data_panel[data_panel$universal_ID == ids[j],]
  data_panel$lagged_personal_rifle[data_panel$universal_ID == ids[j] & data_panel$wave == 0] <- NA
  data_panel$lagged_personal_rifle[data_panel$universal_ID == ids[j] & data_panel$wave == 1] <- data_panel$personal_rifle[data_panel$universal_ID == ids[j] & data_panel$wave == 0]
  data_panel$lagged_personal_rifle[data_panel$universal_ID == ids[j] & data_panel$wave == 2] <- data_panel$personal_rifle[data_panel$universal_ID == ids[j] & data_panel$wave == 1]
  
}

#courtlegit_composite
data_panel$lagged_courtlegit_composite <- NA
for(j in 1: length(unique(data_panel$universal_ID))){
  indiv <- data_panel[data_panel$universal_ID == ids[j],]
  data_panel$lagged_courtlegit_composite[data_panel$universal_ID == ids[j] & data_panel$wave == 0] <- NA
  data_panel$lagged_courtlegit_composite[data_panel$universal_ID == ids[j] & data_panel$wave == 1] <- data_panel$courtlegit_composite[data_panel$universal_ID == ids[j] & data_panel$wave == 0]
  data_panel$lagged_courtlegit_composite[data_panel$universal_ID == ids[j] & data_panel$wave == 2] <- data_panel$courtlegit_composite[data_panel$universal_ID == ids[j] & data_panel$wave == 1]
  
}

#approve_court_recoded
data_panel$lagged_approve_court <- NA
for(j in 1: length(unique(data_panel$universal_ID))){
  indiv <- data_panel[data_panel$universal_ID == ids[j],]
  data_panel$lagged_approve_court[data_panel$universal_ID == ids[j] & data_panel$wave == 0] <- NA
  data_panel$lagged_approve_court[data_panel$universal_ID == ids[j] & data_panel$wave == 1] <- data_panel$approve_court[data_panel$universal_ID == ids[j] & data_panel$wave == 0]
  data_panel$lagged_approve_court[data_panel$universal_ID == ids[j] & data_panel$wave == 2] <- data_panel$approve_court[data_panel$universal_ID == ids[j] & data_panel$wave == 1]
  
}

#courtknow_composite
data_panel$lagged_courtknow_composite <- NA
for(j in 1: length(unique(data_panel$universal_ID))){
  indiv <- data_panel[data_panel$universal_ID == ids[j],]
  data_panel$lagged_courtknow_composite[data_panel$universal_ID == ids[j] & data_panel$wave == 0] <- NA
  data_panel$lagged_courtknow_composite[data_panel$universal_ID == ids[j] & data_panel$wave == 1] <- data_panel$courtknow_composite[data_panel$universal_ID == ids[j] & data_panel$wave == 0]
  data_panel$lagged_courtknow_composite[data_panel$universal_ID == ids[j] & data_panel$wave == 2] <- data_panel$courtknow_composite[data_panel$universal_ID == ids[j] & data_panel$wave == 1]
  
}

#courtsize
data_panel$lagged_courtsize <- NA
for(j in 1: length(unique(data_panel$universal_ID))){
  indiv <- data_panel[data_panel$universal_ID == ids[j],]
  data_panel$lagged_courtsize[data_panel$universal_ID == ids[j] & data_panel$wave == 0] <- NA
  data_panel$lagged_courtsize[data_panel$universal_ID == ids[j] & data_panel$wave == 1] <- data_panel$courtsize[data_panel$universal_ID == ids[j] & data_panel$wave == 0]
  data_panel$lagged_courtsize[data_panel$universal_ID == ids[j] & data_panel$wave == 2] <- data_panel$courtsize[data_panel$universal_ID == ids[j] & data_panel$wave == 1]
  
}

#courtterms
data_panel$lagged_courtterms <- NA
for(j in 1: length(unique(data_panel$universal_ID))){
  indiv <- data_panel[data_panel$universal_ID == ids[j],]
  data_panel$lagged_courtterms[data_panel$universal_ID == ids[j] & data_panel$wave == 0] <- NA
  data_panel$lagged_courtterms[data_panel$universal_ID == ids[j] & data_panel$wave == 1] <- data_panel$courtterms[data_panel$universal_ID == ids[j] & data_panel$wave == 0]
  data_panel$lagged_courtterms[data_panel$universal_ID == ids[j] & data_panel$wave == 2] <- data_panel$courtterms[data_panel$universal_ID == ids[j] & data_panel$wave == 1]
  
}

#court ideology
data_panel$lagged_courtideology <- NA
for(j in 1: length(unique(data_panel$universal_ID))){
  indiv <- data_panel[data_panel$universal_ID == ids[j],]
  data_panel$lagged_courtideology[data_panel$universal_ID == ids[j] & data_panel$wave == 0] <- NA
  data_panel$lagged_courtideology[data_panel$universal_ID == ids[j] & data_panel$wave == 1] <- data_panel$courtideology[data_panel$universal_ID == ids[j] & data_panel$wave == 0]
  data_panel$lagged_courtideology[data_panel$universal_ID == ids[j] & data_panel$wave == 2] <- data_panel$courtideology[data_panel$universal_ID == ids[j] & data_panel$wave == 1]
  
}
